<script type="text/javascript" src="{$base_dir}modules/homecarousel/jquery.jcarousel.pack.js"></script>
{if $autoplay}
	<script type="text/javascript">
		var carousel_autoplay = 5;
		var carousel_items_visible = {$itemsvisible};
		var carousel_scroll = {$itemsscroll};
	</script>
{else}
	<script type="text/javascript">
		var carousel_autoplay = 5;
		var carousel_items_visible = {$itemsvisible};
		var carousel_scroll = {$itemsscroll};
	</script>
{/if}
<script type="text/javascript" src="{$base_dir}modules/homecarousel/homecarousel.js"></script>
<!-- MODULE Home Featured Products -->
{if isset($products) AND $products}
<ul id="mycarousel">
	{foreach from=$products item=product name=homeFeaturedProducts}
	{assign var='productLink' value=$link->getProductLink($product.id_product, $product.link_rewrite)}
	<li {if $smarty.foreach.homeFeaturedProducts.last}class="last_item"{/if}>
		<a href="{$product.link}" title="{$product.manufacturer_name_lang|escape:html:'UTF-8'} - {$product.name|escape:html:'UTF-8'}" class="product_image"><img src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home')}" height="{$homeSize.height}" width="{$homeSize.width}" alt="{$product.manufacturer_name_lang|escape:html:'UTF-8'} - {$product.name|escape:html:'UTF-8'}" /></a>
		{if $displayname}
			<h5 style="text-align:center"><a class="product_link" href="{$link->getManufacturerLink($product.id_manufacturer, $product.manufacturer_link_rewrite)}" title="{$product.manufacturer_name_lang|escape:'htmlall':'UTF-8'}">{if $lang_iso=='en'}{t text=$product.manufacturer_name_lang length='8' encode='true'}{else}{t text=$product.manufacturer_name_lang length='10' encode='true'}{/if}</a> <a class="brand_link">-</a> <a class="brand_link" href="{$productLink}" title="{$product.name}">{if $lang_iso=='en'}{t text=$product.name length='18' encode='true'}{else}{t text=$product.name length='6' encode='true'}{/if}</a></h5>
			<!--h5><a href="{$productLink}" title="{$product.name}">{$product.name|escape:htmlall:'UTF-8'|truncate:30}</a></h5-->
		{/if}
		{if $displayprice}<span class="price">{displayWtPrice p=$product.price}</span>{/if}
	</li>
	{/foreach}
</ul>
{else}
<p>{l s='No products for carousel' mod='homecarousel'}</p>
{/if}
<!-- /MODULE Home Featured Products -->